package cn.com.api.mapper.base;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.*;

import cn.com.api.entity.ApiT_member_partner_task;

//DAO
public interface T_member_partner_taskMapperBase {

	// 根据id查看
	@Select("SELECT * FROM T_MEMBER_PARTNER_TASK  WHERE ID = #{id}")
	public ApiT_member_partner_task findT_member_partner_taskById(Integer id);

	// 查看数据集
	@Select("SELECT * FROM T_member_partner_task")
	public List<ApiT_member_partner_task> findT_member_partner_tasks();

	// 根据条件查看数据集
	public List<Map<String, Object>> findT_member_partner_tasksByMap(HashMap condition);

	// 添加
	// @Insert("INSERT INTO T_MEMBER_PARTNER_TASK (ID, TASK_NAME,
	// INVITE_PARTNER_AMOUNT, INVITE_ENTREPRENEUR_AMOUNT, ADVERT_MONEY,
	// COMPLETE_TIME, EXT1, EXT2, EXT3, EXT4, EXT5, AWARD_MONEY) VALUES
	// (SEQT_MEMBER_PARTNER_TASK_ID.nextVal, #{task_name},
	// #{invite_partner_amount}, #{invite_entrepreneur_amount}, #{advert_money},
	// #{complete_time}, #{ext1}, #{ext2}, #{ext3}, #{ext4}, #{ext5},
	// #{award_money})")
	// @Options(useGeneratedKeys = false, keyProperty = "id")
	public int insertT_member_partner_task(ApiT_member_partner_task t_member_partner_task);

	// 修改
	@Update("UPDATE T_MEMBER_PARTNER_TASK SET TASK_NAME = #{task_name}, INVITE_PARTNER_AMOUNT = #{invite_partner_amount}, INVITE_ENTREPRENEUR_AMOUNT = #{invite_entrepreneur_amount}, ADVERT_MONEY = #{advert_money},deposit = #{deposit},member_level = #{member_level}, COMPLETE_TIME = #{complete_time}, EXT1 = #{ext1}, EXT2 = #{ext2}, EXT3 = #{ext3}, EXT4 = #{ext4}, EXT5 = #{ext5}, AWARD_MONEY = #{award_money}, sign_term = #{sign_term}, bonus_ratio = #{bonus_ratio}, assign_term = #{assign_term} WHERE ID = #{id}")
	public int updateT_member_partner_task(ApiT_member_partner_task t_member_partner_task);

	// 删除
	@Delete("DELETE FROM T_MEMBER_PARTNER_TASK  WHERE ID = #{id}")
	public int deleteT_member_partner_task(Integer id);

	// Foreign keys revelant

	// region Indexs revelant

}
